<?php
	$sql_select="select cName from tblaccount where iGroupId=$id";
	$rs=$dbsql->query($sql_select);
	if($dbsql->num_rows($rs)==0)
	{
		if($id>0)
		{
			$sql_delete = "delete from tblpermission  WHERE  iId=$id";
      		$dbsql->query($sql_delete);
			$msg = "Delete Group Success !";
		}
     }else
	 {
	 	 $msg = "Can't delete group has User !";
	 }
      //-----------------------------------------------------

      page_transfer($msg,$pagetr);

      exit();


?>
